﻿<Window x:Class="CncConvProg.View.Dialog.EditPhaseDetailView"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:ab="clr-namespace:CncConvProg.View.AttachedProperty" xmlns:Resources="clr-namespace:MecPrev.Resources;assembly=MecPrev.Resources" 
        Title="{x:Static Resources:GuiRes.DlgPhaseDetail}" 
        MinHeight="200" MinWidth="300"
        WindowStyle="ToolWindow"
        WindowState="Normal"
        Width="400"
        Height="400"
        WindowStartupLocation="CenterScreen"
        >
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto" />
            <RowDefinition Height="*" />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        <TextBlock Text="{x:Static Resources:GuiRes.DettagliFase}" FontSize="20" />
        <DockPanel Grid.Row="1">
            <StackPanel Orientation="Horizontal" DockPanel.Dock="Top">
                <TextBlock Text="{x:Static Resources:GuiRes.PhaseDescription}" Width="130" Margin="3" />
                <TextBox Text="{Binding Path=DescrizioneFase}" Width="180" />
            </StackPanel>
            <StackPanel Orientation="Horizontal" DockPanel.Dock="Top">
                <TextBlock Text="{x:Static Resources:GuiRes.MachineSelected}" Width="130" Margin="3" />
                <ComboBox SelectedItem="{Binding Path=MacchinaSelezionata}" DisplayMemberPath="MachineName" ItemsSource="{Binding Path=MachineList}" MinWidth="150" />
            </StackPanel>
            <GroupBox DockPanel.Dock="Top" Header="{x:Static Resources:GuiRes.PhaseProperty}" Margin="3,10,3,0" Padding="5">
                <StackPanel>
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="{x:Static Resources:GuiRes.MaxRev}" MinWidth="170" />
                        <TextBox ab:AttachedProperties.AutoSelectText="True"  Text="{Binding Path=LimitatoreGiri}" MinWidth="80" />
                    </StackPanel>
                </StackPanel>
            </GroupBox>
            <GroupBox DockPanel.Dock="Top" Header="{x:Static Resources:GuiRes.TimeCalculationGroup}" Margin="3,10,3,0" Padding="5">
                <StackPanel>
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="{x:Static Resources:GuiRes.SetupFixtureTime}" MinWidth="170" />
                        <TextBox ab:AttachedProperties.AutoSelectText="True"  Text="{Binding Path=SetupFixtureTime}" MinWidth="80" />
                    </StackPanel>
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="{x:Static Resources:GuiRes.SetupToolTime}" MinWidth="170" />
                        <TextBox ab:AttachedProperties.AutoSelectText="True"  Text="{Binding Path=TempoSetupTool}" MinWidth="80" />
                    </StackPanel>
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="{x:Static Resources:GuiRes.ProgrammingOperationTime}" MinWidth="170" />
                        <TextBox  ab:AttachedProperties.AutoSelectText="True"  Text="{Binding Path=TempoProgrammazioneOperazione}" MinWidth="80" />
                    </StackPanel>
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="{x:Static Resources:GuiRes.LoadingMachine}" MinWidth="170" />
                        <TextBox ab:AttachedProperties.AutoSelectText="True"  Text="{Binding Path=LoadingMaterialTime}" MinWidth="80" />
                    </StackPanel>
                </StackPanel>
            </GroupBox>
        </DockPanel>

        <StackPanel Orientation="Horizontal" Grid.Row="3" HorizontalAlignment="Right" Grid.ColumnSpan="2" >
            <Button Content="{x:Static Resources:GuiRes.ButtonCancel}" Width="100" Margin="5" Click="Button_Click_1" />
            <Button Content="Ok" Width="100" Margin="5" Click="Button_Click" />
        </StackPanel>
    </Grid>
</Window>
